export const isSkip = (storName, nextPath, message, isSkip, isdisabled, timer) => {
  isSkip = JSON.parse(localStorage.getItem(`${storName}`))
  if (isSkip === null) {
    message.forEach(item => {
      item.bool = true
    })
    isdisabled = true
    timer = setTimeout(() => {
      message.forEach(item => {
        item.bool = false
      })
      isdisabled = false
    }, 2000)
    return
  }

  if (message.find((item) => item.data.length === 0)) {
    isdisabled = true
    message.forEach(item => {
      if (item.data.length === 0) {
        item.bool = true
      }
    })

    timer = setTimeout(() => {
      message.forEach(item => {
        item.bool = false
      })
      isdisabled = false
    }, 2000)
    return
  }
  this.$router.push(`${nextPath}`)
}
